package com.joelemon.mockinfluxdbdata.common;

/**
 * 通用枚举
 *
 * @author hjg
 **/
public enum ResultCode {

    /**
     * success
     */
    SUCCESS("1", "成功"),

    /**
     * failed
     */
    FAILED("0", "失败"),

    /**
     * 系统异常
     */
    SERVER_INTERNAL_ERROR("-1", "系统异常");

    /**
     * 编码
     */
    private String code;

    /**
     * 描述
     */
    private String desc;

    ResultCode(String code, String desc) {
        this.code = code;
        this.desc = desc;
    }

    public String getCode() {
        return this.code;
    }

    public String getDesc() {
        return desc;
    }

    @Override
    public String toString() {
        return "CommonCodeEnum{" + "code='" + code + '\'' + ", desc='" + desc + '\'' + '}';
    }

}
